{% extends "mybase.html"  %}
    {% block content -%}
    <div class="row clearfix" >
        <div class="col-md-4 col-md-offset-4 column">
            <h2 align="center">添加新计划</h2>
            <form class="form-group" action="/todolist/add" method="post">
                <div class="form-group">
                    <label for=""><span style="color: red">*</span>计划名称</label>
                    <input required class="form-control"  name='task' type="text" placeholder="请输入计划名称">
                </div>
                <div class="form-group">
                    <label for=""><span style="color: red">*</span>详情</label>
                    <input required class="form-control" name='description' type="text"  placeholder="请输入描述">
                </div>
                <div class="form-group">
                    <label for="">类别</label>
                    <input  required class="form-control"  name='category' type="text" placeholder="请输入类别">
                </div>
                <div class="form-group"  >
                    <label for=""><span style="color: red">*</span>到期时间</label>
                    <input required class="form-control" name='expire_time' type="text" id='datetimepicker'>
                </div>
                <div class="text-right">
                    <button class="btn btn-primary" type="submit">提交</button>
                </div>
            </form>
        </div>
    </div>

    {%- endblock content %}
    {% block myscripts %}
    <script type="text/javascript">
        $(document).ready(function () {
            $('#datetimepicker').datepicker({
                format: 'yyyy-mm-dd',
                startDate: '0d'
            });
        });
    </script>
    {% endblock myscripts %}